/*
	File:		IEntity.h
	Course:		SGD 1301
	Author:		dmonroe
	Purpose:	Abstract Base Class for the entities
				defines the 'interface' of the class
*/

#pragma once

#define WIN32_LEAN_AND_MEAN
#include <Windows.h>


////////////////////////////////////////////////////////////
// IEntity class
//	- abstract base class cannot be instantiated
//	- ONLY contains pure virtual methods to expose 
//	  the INTERFACE of the entities
//	- reference counting will deallocate the entity
//	  when it is no longer being used
class IEntity
{
public:

	// Pure virtual method to create an Abstract Base Class
	// Pure virtual methods MUST be overridden in a child class
	virtual ~IEntity( void )		= 0	
	{	/* do nothing */	}

	// IEntity Interface:
	virtual void Update( float fElapsedTime )	= 0;
	virtual void Render( void )					= 0;
	virtual int  GetType( void ) const			= 0;
	virtual RECT GetRect( void ) const			= 0;
	virtual bool CheckCollision( IEntity* pOther )	= 0;

	virtual void AddRef( void )		= 0;
	virtual void Release( void )	= 0;

	int GetHashKey(void)const{return hashKey;}
	void SetHashKey(int key){hashKey = key;}
private:
	int hashKey;
};

